package cn.seaboot.admin.security.auth;

import java.util.Arrays;

/**
 * 请求 url 授权码配置
 *
 * @author Mr.css
 * @version 2023-07-10 11:36
 */
public class AntAuthority {
    /**
     * 路径
     */
    private String ant;
    /**
     * 请求方式
     */
    private String method;
    /**
     * 鉴权类型
     *
     * @see AuthorityType
     */
    private String type;
    /**
     * 所需的授权码列表
     * <p>
     * E.G.: ["ROLE_ADMIN", "system.user.remove"]
     */
    private String[] authority;

    public String getMethod() {
        return method;
    }

    public void setMethod(String method) {
        this.method = method;
    }

    public String getAnt() {
        return ant;
    }

    public void setAnt(String ant) {
        this.ant = ant;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String[] getAuthority() {
        return authority;
    }

    public void setAuthority(String[] authority) {
        this.authority = authority;
    }

    @Override
    public String toString() {
        return "AntAuthority{" +
                "ant='" + ant + '\'' +
                ", method='" + method + '\'' +
                ", type='" + type + '\'' +
                ", authority=" + Arrays.toString(authority) +
                '}';
    }
}
